<?php
$this->breadcrumbs = array(
	'Quản lý địa điểm tổ chức',
);
?>
<!-- BEGIN PORTLET-->
<div class="row">
	<div class="col-md-12">
    	<div class="portlet">
        	<div class="portlet-title">
            	<div class="caption"><i class="icon-bar-chart"></i>Danh sách tổ chức</div>
                <div class="actions">
                    <?php echo CHtml::link('<i class="icon-plus"></i> Địa điểm tổ chức mới', array('/Events/places/create'), array('class'=>'btn blue btn-sm')); ?>
                </div>
            </div>
            <div class="portlet-body">
                <?php $this->widget('zii.widgets.grid.CGridView', array(
                	'id'=>'slide-grid',
                	'dataProvider'=>$model->search(),
                	'ajaxUpdate'=>true,
                	'filter'=>$model,
                	'itemsCssClass'=>'table table-striped table-bordered table-advance table-hover',
                	'pager'=>array(
                        'header'=>'',
                		'maxButtonCount'=>10,
                        'header'=>'',
                        'prevPageLabel'=>'<i class="icon-angle-left"></i></a>',
                        'nextPageLabel'=>'<i class="icon-angle-right"></i></a>',
                        'firstPageLabel'=>'First',
                        'lastPageLabel'=>'Last',
                        'footer'=>'',
                		'selectedPageCssClass'=>'active',
                		'hiddenPageCssClass'=>'disabled',
                        'htmlOptions'=>array(
                            'class'=>'pagination pagination-sm',
                        ),
                    ),
                	'columns'=>array(
                		array(
                            'name'=>'title',
                            'value'=>'$data->title',
                        ),
                        array(
                            'name'=>'url',
                            'value'=>'$data->url',
                        ),
                        array(
                			'name'=>'createddate',
                			'value'=>'date("d-m-Y", strtotime($data->createddate))',
                		),
                		array(
                			'class'=>'CButtonColumn',
                			'header'=>'Action',
                			'template'=>'{view} {update} {delete}',
                			'buttons'=>array
                			(
                				'view'=>array(
                					'label'=>'<i class="icon-share"></i>',
                					'imageUrl'=>false,
                					'options'=>array(
                						'class'=>'btn default btn-xs blue',
                						'title'=>'View'
                					),
                				),
                				'update'=>array(
                					'label'=>'<i class="icon-edit"></i>',
                					'imageUrl'=>false,
                					'options'=>array(
                						'class'=>'btn default btn-xs green',
                						'title'=>'Edit'
                					),
                				),
                				'delete'=>array(
                					'label'=>'<i class="icon-trash"></i>',
                					'imageUrl'=>false,
                					'options'=>array(
                						'class'=>'btn default btn-xs black',
                						'title'=>'Delete'
                					),
                				),
                			),
                			'htmlOptions'=>array(
                				'width'=>'100px',
                				'class'=>'text-center'
                			),
                		),
                	),
                	'htmlOptions'=>array(
                		'class'=>''
                	),
                )); ?>
            </div>
        </div>
    </div>
</div>